#ifndef HALF_EDGE_H
#define HALF_EDGE_H

#include <iostream>

class Vertex;
class Edge;
class Face;
class Loop;

class HalfEdge{
    public:
        HalfEdge(int = 0, Vertex * = NULL, Loop * = NULL, Edge * = NULL, HalfEdge * = NULL);
        ~HalfEdge(){};

        int getId() const {return id;};
        void setId(int _id) {id = _id;};

        Vertex *getVertex() const {return vertex;};
        void setVertex(Vertex *_v) {vertex = _v;};

        Loop *getLoop() const {return loop;};
        void setLoop(Loop *_l) {loop = _l;};

        Edge *getEdge() const {return edge;};
        void setEdge(Edge *_e) {edge = _e;};

        HalfEdge *getTwin() const;

        HalfEdge *getNext() const {return next;};
        void setNext(HalfEdge *_he) {next = _he;};

    private:
        int id;
        Vertex *vertex;
        Loop *loop;
        Edge *edge;

        HalfEdge *next;
};

#endif
